package com.mycompany.app.common.entity;

import javax.persistence.MappedSuperclass;

import org.apache.commons.lang.builder.ToStringBuilder;


@MappedSuperclass
public class BaseEntity extends BaseObject {
    
    private static final long serialVersionUID = -21600358914967376L;

    protected Integer version;

    public Integer getVersion() {

        return version;
    }

    public void setVersion(Integer version) {

        this.version = version;
    }

//    public boolean equals(Object o) {
//
//        if (o instanceof BaseEntity == false) {
//            return false;
//        }
//        if (this == o) {
//            return true;
//        }
//        BaseEntity be = (BaseEntity) o;
//        return new EqualsBuilder().append(id, be.getId()).isEquals();
//    }
//
//    public int hashCode() {
//
//        return new HashCodeBuilder(17, 37).append(id).toHashCode();
//    }

    public String toString() {
        return ToStringBuilder.reflectionToString(this);
    }

    @Override
    public boolean equals(Object o) {

        // TODO Auto-generated method stub
        return false;
    }

    @Override
    public int hashCode() {

        // TODO Auto-generated method stub
        return 0;
    }

}
